package com.longge;

/**
 * @program: my-code
 * @description:
 * @author: longge
 * @create: 2021-03-08 23:48
 */
public class Shuffle {
    public int[] shuffle(int[] nums, int n) {

        int[] res = new int[nums.length];
        for (int i = 0,middle = nums.length / 2,j=0; middle < nums.length; i++,middle++) {
            res[j++]=nums[i];
            res[j++]=nums[middle];
        }
        return res;
    }
}
